package com.lqian.blog.service;

import com.lqian.blog.dao.pojo.SysUser;
import com.lqian.blog.vo.Result;
import com.lqian.blog.vo.UserVo;

public interface SysUserService {

    /**
     * @Author Melody_LQ
     * @Date 2021/9/2 21:16
     * @Description 根据id查询用户信息
     * @Param @param id:
     * @Return com.lqian.blog.dao.pojo.SysUser
     * @Since version-1.0
     */
    SysUser findUserById(Long id);

    /**
     * @Author Melody_LQ
     * @Date 2021/9/2 21:16
     * @Description 用户账号密码登录
     * @Param @param account:
     * @param pwd:
     * @Return com.lqian.blog.dao.pojo.SysUser
     * @Since version-1.0
     */
    SysUser findUser(String account, String pwd);

    /**
     * @Author Melody_LQ
     * @Date 2021/9/2 22:49
     * @Description 根据请求头携带的token 查询该用户信息
     * @Param @param token:
     * @Return com.lqian.blog.vo.Result
     * @Since version-1.0
     */
    Result getUserInfoByToken(String token);

    SysUser findUserByAccount(String account);

    void save(SysUser sysUser);

    /**
     * @Author Melody_LQ
     * @Date 2021/9/12 9:44
     * @Description 根据作者id查询返回UserVo
     * @Param @param authorId:
     * @Return com.lqian.blog.vo.UserVo
     * @Since version-1.0
     */
    UserVo findUserVoById(Long authorId);
}
